<template>
  <div class="category-goods">
    <scroll class="content" ref="scroll" :probe-type="3" :pull-up-load="true">
      <div class="main">
        <div class="item" :key="index" v-for="(item, index) in categorygoods">
          <a :href="item.link">
            <img :src="item.image" alt="" />
            <span>{{ item.title }}</span>
          </a>
        </div>
      </div>
    </scroll>
  </div>
</template>

<script>
import Scroll from "components/common/scroll/Scroll.vue";
export default {
  name: "CategoryGoods",
  components: { Scroll },
  props: {
    categorygoods: {
      type: Array,
      default() {
        return [];
      },
    },
  },
};
</script>

<style scoped>
.category-goods {
  width: 75vw;
  height: 100vh;
  background: #fff;

}
.content {
  height: calc(100% - 93px);
  overflow: hidden;
  
}
.main {
  display: flex;
  flex-wrap: wrap;
  margin-left: 10px;
}
.item {
  width: 33.3%;
  text-align: center;
  padding: 5px;
}
.item img {
  width: 100%;
}
</style>
